One of the many benefits of using digital images is the ease with which the images can be used for different purposes. Images captured with a digital camera are immediately available to view, print and share with others by email or web page. Photographers enjoy the ability to easily manipulate their images to improve their quality and artistic expression. Image manipulation can be performed manually, under the user's control, or automatically, using a variety of algorithms to evaluate and modify an image to improve its quality in some way. Manipulations can be performed in a digital camera, at the time of capture or during later review, using a personal computer with image editing software, using editing tools on a web site.
Cropping is one of the most common manipulations. Cropping an image means to select a desired region of the image and create a new image consisting only of the desired region, discarding the surrounding region. Cropping is normally done to improve the composition of the image, enlarging or repositioning the main subject and discarding distracting subject elements or uninteresting background areas. Cropping is also necessary when the aspect ratio of the original image does not match the aspect ratio of a desired print, display or other output format.
Aspect ratio refers to the ratio of the longer dimension of an image or print to the shorter dimension. Table 1 lists several common print and display formats and their aspect ratios.
TABLE 12 × 3 inch print (wallet size)3:21.53.5 × 5 inch print (3R)10:7 1.434 × 6 inch print (4R)3:21.55 × 7 inch print7:51.48 × 10 inch print5:41.2516 × 20 inch print5:41.2520 × 30 inch print (poster)3:21.5NTSC television4:31.33HDTV television16:9 1.78VGA (640 × 480)4:31.33
It is common in the industry to refer to aspect ratios using two numbers (as 3:2). The table also shows the normalized ratio (as 1.5) for each example, so that it is easier to compare ratios. The larger the aspect ratio is numerically, the “longer” or “narrower” the image is said to be. Images can be presented in vertical (portrait) or horizontal (landscape) orientations. Aspect ratio is properly the ratio of the width of the image to the height. This usage is consistent in the fields of video and computer displays, but in the photographic industry, it is common to ignore orientation when stating aspect ratio. Thus, a 4×6 print is described as having an aspect ratio of 3:2 whether it is horizontally or vertically displayed. For clarity, in the following description, aspect ratios will always be stated in the form width:height. For example, a portrait orientation crop for a 4×6 print size will be stated as a 2:3 crop.
A problem arises when re-cropping an image for a different aspect ratio. This problem is illustrated in FIGS. 1A through 1C. In FIG. 1A, an original image 110 of two children is captured by a user with a digital camera having a 3:2 aspect ratio. After capture, the user wishes to make a 4×6 print of the original image 110. The user crops the original image 110 using an image editing program on a personal computer so that the images of the children mostly fill a cropped image area 115, unwanted subject matter 112 is excluded, and the aspect ratio is 3:2 in order to fill the 4×6 print paper. The user saves the cropped image 120 in place of the original image 110. Later, the user wishes to make an 8×10 print of image 120 and frame it for a gift. Since the aspect ratio of the 8×10 print is different from the aspect ratio of the original 3:2 crop, the user must choose how to reformat image 120 for the 5:4 aspect ratio of the print. A crop area 135 smaller than image 120 will cut off portions 132 and 134 of the images of the children's faces. A crop area 145 larger than image 120 will result in a print with blank spaces 142 and 144 above and below the image area. Both choices have problems that result in an unsatisfactory framed image.
The problem set forth above has been addressed in some instances by keeping the original image data intact and recording the position and size of the crop rectangle in the metadata of the image file. This approach was used in the FlashPix image format, which was specified in the “FlashPix Format Specification, version 1.0, published in September 1996 by Eastman Kodak Company. The FlashPix format included an optional “transform property set” which defined how the image data should be transformed before being displayed or printed. The transform property set includes an optional “rectangle of interest” property and an optional “result aspect ratio” property. These properties can be used to provide data that specifies how an image should be cropped before display or printing. The “rectangle of interest” property includes four data values which define the left edge, top edge, width, and height of the rectangle of interest within the image. The digital image in a FlashPix image file can be cropped to this rectangle of interest before being displayed or printed. The “result aspect ratio” property is a number that can be used to define a rectangle of a specific aspect ratio. Pixels outside this rectangle are cropped by FlashPix applications which read the file and display or print the image. As a result, when a FlashPix format image is edited, cropping can be performed by changing the “rectangle of interest” property, without modifying any of the image data in the file. Unfortunately, such FlashPix files can only be opened by a limited selection of software applications. Furthermore, the image file is large, even if significant cropped is performed, because it contains all of the data in the original. Furthermore, some FlashPix applications ignored the transform property set, because it was optional, and therefore displayed the uncropped, original image.
It is also possible to store crop information in an industry standard file format, such as the JPEG format. In this case, the image can be opened by many applications, but most will ignore the crop information and display the original, uncropped image.